<?php

namespace App\Http\Controllers;


/**
 *
 * Author: TheSmile
 * Date: 2023/5/19 14:29
 * Email: <594652523@qq.com>
 */
class IndexController
{

    public function index()
    {

        return 'hello';
    }

    public function fileDownload($arg1, $arg2)
    {
//        $filename = request()->filename;
//        dd($filename);
        $filePath = public_path('uploads/report/' . $arg1);
        if (!file_exists($filePath)) {
            abort(404);
        }
        return response()->file($filePath);
    }

    public function scanCode($id)
    {
        return $id;
    }


}

